/*
 * Copyright (c) 1994-2017, Joyoung Stock CO.LTD.
 * The FWJR Project.
 * All Rights Reserved.
 */

package com.jz.jd.rest.constant;

import android.support.annotation.IntDef;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;

/**
 * 监控APP专用REST接口常量
 *
 * @author ActonYuan (yuanmingming@joyoung.com)
 * @version Version    Time                  Description<br>
 *          1.0       2016/6/29 17:24       Create<br>
 */
public class MonitorConstant {
    public static final String HOST = "http://112.124.102.114:8089/";
//    public static final String HOST = "http://192.168.199.182/";
    public static final String BASE_URL = "appTest/in/";

    /**
     * 手机号绑定推送CID
     */
    public static final String METHOD_BIND_PHONE_CID = "general!bindingGetuiUser";
    /**
     * 检测更新
     */
    public static final String METHOD_CHECK_UPDATE = "general!version";

    /**
     * 获取相册列表
     */
    public static final String METHOD_GET_ALBUM_IMG_LIST = "img!list";
    /**
     * 批量删除相册照片
     */
    public static final String METHOD_DELETE_IMG_LIST = "general!deleteimgs";

    /**
     * 相册类型
     */
    @IntDef(value = {ALBUM_TYPE.ALARM, ALBUM_TYPE.ALBUM})
    public @interface ALBUM_TYPE {
        /**
         * 报警消息（无论是否推送消息）
         */
        int ALARM = 1;
        /**
         * 相册（包括拍照生成的照片、报警消息保存到相册中的照片）
         */
        int ALBUM = 3;
    }

    /**
     * 设置看家模式时间段
     */
    public static final String METHOD_SET_MONITOR_TIME_SECTION = "general!getuiUserTime";

    /**
     * 是否保存到相册
     */
    @IntDef(value = {IS_SAVE_TO_ALBUM.NOT_SAVE, IS_SAVE_TO_ALBUM.SAVE})
    public @interface IS_SAVE_TO_ALBUM {
        int NOT_SAVE = 0;
        int SAVE = 1;
    }

    public static final String METHOD_UPLOAD_INFO = "general!uploadInfo";

    /**
     * 推送类型
     */
    @IntDef(value = {PUSH_TYPE.MONITOR, PUSH_TYPE.TEXT, PUSH_TYPE.ALBUM})
    public @interface PUSH_TYPE {
        /**
         * 抓拍并推送
         */
        int MONITOR = 1000;
        /**
         * 文字推送
         */
        int TEXT = 2000;
        /**
         * 相册，暂不推送
         */
        int ALBUM = 3000;
    }

    /**
     * 查询用户
     */
    public static final String METHOD_SEARCH_USER = "general!getByPhone";
    /**
     * 添加或删除好友
     */
    public static final String METHOD_FRIEND = "general!savaOrUpdatafriends";

    /**
     * 查询所有好友
     */
    public static final String METHOD_FINDALL_FRIEND = "general!findAll";

    /**
     * 对好友关系的操作
     */
    @IntDef(value = {FRIEND_ACTION.DELETE, FRIEND_ACTION.ADD})
    @Retention(RetentionPolicy.SOURCE)
    public @interface FRIEND_ACTION {
        int DELETE = 0;
        int ADD = 1;
    }

    /**
     * 设置里面的两个开关
     */
    public static final String METHOD_SET_SETTINGS = "general!setalarm";
    public static final String METHOD_GET_SETTINGS = "general!getAlarmState";

    /**
     * 设置中的开关项
     */
    @IntDef(value = {WHICH_SWITCH.SMOKE_ALARM, WHICH_SWITCH.IS_USE_NETWORK})
    @Retention(RetentionPolicy.SOURCE)
    public @interface WHICH_SWITCH {
        int SMOKE_ALARM = 1;
        int IS_USE_NETWORK = 2;
    }

    /**
     * 设置中开关状态
     */
    @IntDef(value = {SWITCH_STATE.ON, SWITCH_STATE.OFF})
    @Retention(RetentionPolicy.SOURCE)
    public @interface SWITCH_STATE {
        int OFF = 0;
        int ON = 1;
    }

    /**
     * 看家模式
     */
    public static final String METHOD_GET_GUARDING_MODE = "general!guardingMode";

    /**
     * 推送消息
     */
    public static final String METHOD_PUSH_MSG = "general!push";

    /**
     * 推送类型（来源）
     */
    @IntDef(value = {PUSH_FROM.PHONE, PUSH_FROM.ROBOT})
    public @interface PUSH_FROM {
        int PHONE = 1;
        int ROBOT = 2;
    }

}
